﻿<%@ Page Language="C#" AutoEventWireup="true" CodeFile="demoScriptReference.aspx.cs" Inherits="JavaScript_demoScriptReference" %>

<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" 
    "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">

<script type="text/javascript">

  function pageLoad() {
    
    $(function() {
      $('#btn').bind('click', function() {
          var $el = $(this);
          var text = ControlAccessor.GetControlValue($el);
          ControlAccessor.SetControlValue($el, text + text);

          return false;
      });
    });
  }
</script>

<html xmlns="http://www.w3.org/1999/xhtml">
<head id="Head1" runat="server">
    <title>ScriptReference</title>
</head>
<body>
    <form id="form2" runat="server">
        <div>
          <asp:ScriptManager 
            ID="ScriptManager2" 
            EnablePartialRendering="True"
            runat="server">
              <Scripts>
                <asp:ScriptReference 
                  Assembly="JUtil.Web" 
                  Name="JUtil.Web.JavaScript.jutil-all.js" />
              </Scripts>
          </asp:ScriptManager>
          
          <asp:Button 
            ID="btn" 
            Text="I am Button"
            runat="server" />
            
        </div>
    </form>
</body>
</html>
